﻿using System;

class ProductOfThreeRealNumbers
{
    static void Main()
    {
        //Exercise 2.
        //Write a program that shows the sign (+ or -) of the product of three real numbers without calculating it. 
        //Use a sequence of if statements.

        Console.Write("Enter the first real number:  ");
        double firstNumber = double.Parse(Console.ReadLine());
        Console.Write("Enter the second real number:  ");
        double secondNumber = double.Parse(Console.ReadLine());
        Console.Write("Enter the third real number:  ");
        double thirdNumber = double.Parse(Console.ReadLine());
        Console.WriteLine();

        if ((firstNumber == 0) | (secondNumber == 0) | (thirdNumber == 0))
        {
            Console.WriteLine("The product is 0.");
        }
        else if (firstNumber < 0 ^ secondNumber < 0 ^ thirdNumber < 0)
        {
            Console.WriteLine("The product sign is - .");
        }
        else if (firstNumber > 0 ^ secondNumber > 0 ^ thirdNumber > 0)
        {
            Console.WriteLine("The product sigh is + .");
        }
        Console.WriteLine();
    }
}

